package com.example.testblog.service;

import com.example.testblog.Dao.UserRepository;
import com.example.testblog.entity.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class UserServiceImpl implements  UserService {

    @Autowired
    private UserRepository userRepository;

    @Override
    public User chekuser(String username, String password) {

       User user=userRepository.findByUsernameAndPassword(username,password);

        return user;
    }
}
